<!--#include file="Config.asp" -->
<%
'删除开放设置,1=允许删除，0=不允许删除操作
IsDel=0

UrlID=int(Request("Urlid"))
LogTypeID=int(Request("LogTypeID"))
ActionType=request("ActionType")

set rs=server.createobject("adodb.recordset")

'SaveAdd
if ActionType="AddUrlSave" And request("title")<>"" then
sql="select * from plan_URL where id is null"
rs.open sql,conn,1,3
rs.addnew
rs("title")=Trim(Request("title"))
rs("myurl")=Trim(Request("myurl"))
rs("info")=Trim(Request("info"))
rs("userid")=Trim(session("AnyPIM_userID"))
rs("ClassID") =Trim(Request("classID"))
rs.Update
rs.close
response.redirect Request.ServerVariables("Http_referer")
end if

'SaveUrlMod
if ActionType="ModUrlSave" and request("UrlID")<>"" And request("title")<>"" then
sql="select * from plan_URL where id="&UrlID
rs.open sql,conn,1,3
rs("ClassID") =int(Request("classID"))
rs("title")=Trim(Request("title"))
rs("myurl")=Trim(Request("myurl"))
rs("info")=Trim(Request("info"))
rs("userid")=int(session("AnyPIM_userID"))
rs.Update
rs.close
'response.redirect Request.ServerVariables("Http_referer")
response.redirect "UrlDetail.asp?UrlID="&UrlID
end If

'SaveAddLog
if ActionType="SaveAddLog" And request("content")<>"" And request("UrlID")<>"" then
sql="select * from plan_URLLog where id is null"
rs.open sql,conn,1,3
rs.addnew
rs("UrlID")=UrlID
rs("Content")=Trim(Request("Content"))
rs("userid")=int(session("AnyPIM_userID"))
rs("LogID") =int(Request("LogTypeID"))
rs("DoTime")=now()
rs.Update
rs.close
response.redirect Request.ServerVariables("Http_referer")
end if
%>
